/*    */ package com.qmsk.servlet;
/*    */ 
/*    */ import com.qmsk.business.shopList.ShopMap;
/*    */ import com.qmsk.business.sys.autono.dao.AutoNoDAO;
/*    */ import com.qmsk.business.util.ConfigUtil;
/*    */ import com.qmsk.business.weixin.customMenu.weiXinUtil.WeiXinUtil;
/*    */ import com.utils.http.HttpAutoLogin;
/*    */ import com.utils.http.HttpLogin;
/*    */ import javax.servlet.ServletException;
/*    */ import javax.servlet.http.HttpServlet;
/*    */ import org.apache.log4j.Logger;
/*    */ import org.springframework.context.ApplicationContext;
/*    */ import org.springframework.web.context.support.WebApplicationContextUtils;
/*    */ 
/*    */ public class CInitialParams extends HttpServlet
/*    */ {
/* 19 */   private static final Logger logger = Logger.getLogger(CInitialParams.class);
/*    */   private static final long serialVersionUID = 1L;
/*    */   private static final String VERSION_INFO = "CarSale server release 0.1 (2012-02-06)";
/*    */ 
/*    */   public void init()
/*    */     throws ServletException
/*    */   {
/* 25 */     logger.info("initial begin...");
/* 26 */     ApplicationContext context = 
/* 27 */       WebApplicationContextUtils.getRequiredWebApplicationContext(getServletContext());
/* 28 */     logger.info("CarSale server release 0.1 (2012-02-06)");
/* 29 */     AutoNoDAO autoNoDAO = (AutoNoDAO)context.getBean("AutoNoDAO");
/* 30 */     AutoNoDAO.setInstance(autoNoDAO);
/* 31 */     ShopMap shopMap = (ShopMap)context.getBean("ShopMap");
/* 32 */     ShopMap.setInstance(shopMap);
/*    */     try {
/* 34 */       ShopMap.init();
/*    */     } catch (Exception e) {
/* 36 */       logger.error(e);
/*    */     }
/* 38 */     HttpLogin httpLogin = (HttpLogin)context.getBean("HttpLogin");
/* 39 */     httpLogin.init();
/* 40 */     HttpAutoLogin.setHttpLogin(httpLogin);
/* 41 */     WeiXinUtil.APPID = ConfigUtil.getValue("APPID");
/* 42 */     WeiXinUtil.APPSECRET = ConfigUtil.getValue("APPSECRET");
/* 43 */     WeiXinUtil.ACCESS_TOKEN_URL = ConfigUtil.getValue("ACCESS_TOKEN_URL");
/* 44 */     logger.error("AppId:" + WeiXinUtil.APPID);
/* 45 */     logger.error("APPSECRET:" + WeiXinUtil.APPSECRET);
/* 46 */     logger.error("ACCESS_TOKEN_URL:" + WeiXinUtil.ACCESS_TOKEN_URL);
/* 47 */     logger.info("initial end.");
/*    */   }
/*    */ }

/* Location:           C:\Users\Administrator\Desktop\新建文件夹\WEB-INF\classes\
 * Qualified Name:     com.qmsk.servlet.CInitialParams
 * JD-Core Version:    0.5.3
 */